import {Select, Upload, NavPages, Image} from '../../../components/components.js';
import { LANG } from '../../../config/config.js';

const jump = ReactRouter.hashHistory;

class orderList extends React.Component {
  constructor(props) {
    super(props);

    this.detailsClick = this.detailsClick.bind(this);

  }

  detailsClick() {
    jump.push({
      pathname : `orderManagement/orderDetails/${1234}`,
     //  query : {token : localStorage.token },
      state : {fromDashboard : true }
    })
  }

  render() {
    return (
      <div className="orderManagement container-fluid">
        <NavPages nav={[LANG[Lang].home, LANG[Lang].orderManagement]}/>
          <div className="orderManagement-body">
            <div className="orderManagement-tool">
              <Select value='23456' option={[{
                  name: '12345', value: "12345"
                }, {
                  name: '23456', value: "23456"
                }, {
                  name: '34567', value: "34567"
                }]} selectClick={name,value => {console.log(value);}}/>
              <Upload />
            </div>
            <div className="orderManagement-order">
              <div className="orderManagement-order-tool">
                <strong>检测单号</strong>
                <div className="pull-right">
                  <span></span>
                  <span></span>
                  <span></span>
                </div>
                <button type="button" className="btn btn-success" onClick={this.detailsClick}>检测详情</button>
              </div>
              <table className="table table-hover table-bordered">
                <thead>
                  <tr>
                    <th>头像</th>
                    <th>姓名</th>
                    <th>身份</th>
                    <th>手机号</th>
                    <th>所属主管</th>
                  </tr>
                </thead>
                <tbody>
                  <tr>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                  </tr>
                  <tr>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                  </tr>
                  <tr>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                    <td>123</td>
                  </tr>
                </tbody>
              </table>
            </div>
          </div>
          <Image/>
          <Image/>
          <Image/>
          <Image/>
          <Image/>
          <Image/>
          <Image/>
      </div>
    )
  }
}
module.exports = orderList;
